package com.aodonghao.service.impl;

import com.aodonghao.domain.Student;
import com.aodonghao.mapper.StudentMapper;
import com.aodonghao.service.StudentService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;
@Service
public class StudentServiceImpl  implements StudentService {
    @Autowired
    private StudentMapper studentMapper;
    public List<Student> findAll() {
        return studentMapper.findAll();
    }

    public void save(Student student) {
        studentMapper.save(student);
    }

    public Student findByNumber(String number) {
        return studentMapper.findByNumber(number);
    }

    public void update(Student student) {
         studentMapper.update(student);
    }

    public void delete(String number) {
        studentMapper.delete(number);
    }

}
